package com.rj1101.hscrm.demo.action;

import java.util.List;

import javax.servlet.http.HttpServletRequest;

import org.apache.struts2.ServletActionContext;

import com.opensymphony.xwork2.ActionSupport;
import com.rj1101.hscrm.demo.model.HcrmRole;
import com.rj1101.hscrm.demo.service.impl.SystemServiceImpl;

public class HcrmRoleAction extends ActionSupport{

	private HcrmRole hr;
	private SystemServiceImpl systemService;
	private List<HcrmRole> hrList;
	
	public HcrmRole getHr() {
		return hr;
	}
	public void setHr(HcrmRole hr) {
		this.hr = hr;
	}
	public SystemServiceImpl getSystemService() {
		return systemService;
	}
	public void setSystemService(SystemServiceImpl systemService) {
		this.systemService = systemService;
	}
	public String findAllHcrmRoleInfo() throws Exception	{
		hrList = systemService.findAllHcrmRole();
		HttpServletRequest request = ServletActionContext.getRequest();
		request.setAttribute("hrList", hrList);
		return SUCCESS;
		
	}
}
